7f756d5762710c8284407c6cc6ed69ce16f9392d — Cadence Ember 1 year, 9 months ago 539260c
Add narration to "can't think" page
5 files changed, 34 insertions(+), 3 deletions(-)

M .gitignore
M pug/cant-think.pug
M sass/includes/cant-think-page.sass
M server.js
M utils/constants.js
M .gitignore => .gitignore +3 -0
@@ 11,3 11,6 @@ node_modules
# User configuration

# Narration

M pug/cant-think.pug => pug/cant-think.pug +8 -1
@@ 19,6 19,13 @@ mixin leave(index, prefix="No more?", final)

block content
    - let src = constants.server_setup.cant_think_narration_url
    if src
        div You can listen to this page narrated by #[a(href="https://suricrasia.online") Suricrasia Online].
          audio(controls src=src preload="metadata").page-narration__audio
      p Oh?
      p You can't think of anything to watch, yet you're still here?

@@ 59,7 66,7 @@ block content
      p Pieces of your brain twist and fall apart as you shake off the identity that the billion-dollar distraction manufacturers have handed to you, the identity that you once willingly accepted without even realising that it was there.
      p I beg of you, find something.
      p Create. Discover. Seek. Learn.
      p You see it now, don't know?
      p You see it now, don't you?
      p You understand.
      p You know what you must do.
      p.ultimatum: a(href="#i-understand").border-look I know what I must do.

M sass/includes/cant-think-page.sass => sass/includes/cant-think-page.sass +18 -1
@@ 1,4 1,5 @@
@use "sass:list"
@use "colors.sass" as c


@@ 6,9 7,24 @@

    text-align: left
    max-width: 540px
    max-width: 572px
    padding-top: 40px
    border-radius: 0px 0px 16px 16px
    box-sizing: border-box

    background-color: c.$bg-accent
    border: 1px solid #aaa
    color: #fff
    border-radius: 0
    padding: 16px
    margin: 40px auto 60px

      margin-top: 20px

      width: 100%

    margin: 26px 32px !important

@@ 22,6 38,7 @@
      font-weight: bold
      color: #f2f2f2
      text-align: center

        display: block

M server.js => server.js +2 -0
@@ 1,5 1,6 @@
const {Pinski} = require("pinski")
const {setInstance} = require("pinski/plugins")
const constants = require("./utils/constants")

;(async () => {
	await require("./utils/upgradedb")()

@@ 11,6 12,7 @@ const {setInstance} = require("pinski/plugins")

	server.pugDefaultLocals.constants = constants


M utils/constants.js => utils/constants.js +3 -1
@@ 32,7 32,9 @@ let constants = {
		// The URL of the local NewLeaf instance, which is always used for subscription updates.
		local_instance_origin: "http://localhost:3000",
		// Whether users may filter videos by regular expressions. Unlike square patterns, regular expressions are _not_ bounded in complexity, so this can be used for denial of service attacks. Only enable if this is a private instance and you trust all the members.
		allow_regexp_filters: false
		allow_regexp_filters: false,
		// Audio narration on the "can't think" page. `null` to disable narration, or a URL to enable with that audio file.
		cant_think_narration_url: null

	// ***                                                 ***